//
//  ViewController.m
//  TestKeychain
//
//  Created by weihong xuan on 2017/12/14.
//  Copyright © 2017年 weihong xuan. All rights reserved.
//

#import "ViewController.h"
#import "TCKeychain.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    NSString * testStr = @"要保存的字符";
    [TCKeychain setObject:testStr forKey:@"passwordKey"];//保存
    
    NSString * getStr = [TCKeychain getObjectForKey:@"passwordKey"];//读取
    NSLog(@"获取保存的字符：%@",getStr);
    /*
     保存后删除手机上的app，屏蔽保存代码，直接读取文件照样还在；
     */
}
- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}


@end
